Skip to content

fix: remove stray worktree gitlink that breaks every recursive checkout - #145

Merged
hyperpolymath merged 1 commit into
mainfrom
fix/stray-worktree-gitlink
Jul 29, 2026
Merged

fix: remove stray worktree gitlink that breaks every recursive checkout#145
hyperpolymath merged 1 commit into
mainfrom
fix/stray-worktree-gitlink

Conversation

@hyperpolymath

Copy link
Copy Markdown
Owner

The last red check on main

.claude/worktrees/maa-ci-repair is committed on main as a gitlink (mode 160000, pointing at 0392152) with no matching entry in .gitmodules. Git treats that as an unmapped submodule and refuses:

##[error]fatal: No url found for submodule path '.claude/worktrees/maa-ci-repair' in .gitmodules
##[error]The process '/usr/bin/git' failed with exit code 128

That is the OSSF Scorecard failure on main. It dies during checkout, before running a single scorecard probe — so the red tick says nothing about this repo's actual security posture.

It also breaks any git clone --recurse-submodules and any actions/checkout with submodules: true.

Where it came from

A Claude Code worktree is local scratch and must never be tracked. It was committed by accident in #142 (fix(ci): repoint codeql-action at a SHA that exists) — the same commit -a-on-a-dirty-tree that carried the squisher-corpus guix.scm clobber onto main (fixed separately in #143). One careless -a, two unrelated defects.

Why this shape matters

This repo has been bitten by exactly this before. Commit 639f389 (2026-02-21) left aletheia as a gitlink with no .gitmodules entry. A gitlink without its mapping resolves to a silently-empty directory — git's quietest failure mode — and that one went unnoticed for over a month until the pointer was swept away and 361 files were vendored in its place.

Fix

  • git rm --cached .claude/worktrees/maa-ci-repair — index only, contents untouched on disk
  • add .claude/worktrees/ to .gitignore so it cannot recur

Verification

$ git submodule status
 87902bb770e767c10e065d9ac75d111e80a01be1 absolute-zero (heads/main)     # exit 0

$ git check-ignore -v .claude/worktrees/maa-ci-repair
.gitignore:136:.claude/worktrees/	.claude/worktrees/maa-ci-repair

Only absolute-zero remains, which is the one genuine submodule and is correctly mapped.

🤖 Generated with Claude Code

`.claude/worktrees/maa-ci-repair` is committed on main as a **gitlink**
(mode 160000, pointing at 0392152) with **no matching entry in .gitmodules**.
Git treats that as an unmapped submodule and refuses:

    ##[error]fatal: No url found for submodule path
             '.claude/worktrees/maa-ci-repair' in .gitmodules
    ##[error]The process '/usr/bin/git' failed with exit code 128

That is the OSSF Scorecard failure on main — it dies during checkout, before
running a single scorecard probe. Any `git clone --recurse-submodules` or
`actions/checkout` with `submodules: true` fails the same way.

A Claude Code worktree is local scratch. It must never be tracked at all; it was
committed by accident in #142 (`fix(ci): repoint codeql-action at a SHA that
exists`) — the same `commit -a`-on-a-dirty-tree that carried the squisher-corpus
`guix.scm` clobber onto main (fixed separately in #143).

Fix: drop it from the index (`git rm --cached`, contents untouched on disk) and
add `.claude/worktrees/` to .gitignore so it cannot recur.

This repo has been bitten by exactly this shape before: `639f389` (2026-02-21)
left `aletheia` as a gitlink with no .gitmodules entry, and a gitlink without its
mapping resolves to a silently-empty directory — git's quietest failure. That one
went unnoticed for over a month.

Verified: `git submodule status` now lists only `absolute-zero` and exits 0;
`git check-ignore` confirms the path is ignored; the worktree itself is
untouched on disk.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@gitar-bot

gitar-bot Bot commented Jul 29, 2026

Copy link
Copy Markdown

Note

Automatic reviews are paused because your trial's included automatic processing has been used for this period. Upgrade now, or comment "Gitar review" to run a review anytime.
Learn more

Code Review ✅ Approved

Removes the stray untracked gitlink for .claude/worktrees/maa-ci-repair and adds the directory to .gitignore to unblock recursive checkouts. No issues found.

Auto-approved and auto-merge armed: No blocking issues found.
Please see Auto-approve Docs for details on setting custom approval criteria. — merges when pipeline and required approvals pass.

Options

Display: compact → Showing less information.

Comment with these commands to change the behavior for this request:

Compact
gitar display:verbose         

Was this helpful? React with 👍 / 👎 | Gitar

@gitar-bot

gitar-bot Bot commented Jul 29, 2026

Copy link
Copy Markdown

⚠️ Gitar auto-approved this PR but could not enable auto-merge: auto-merge is disabled for this repository — enable "Allow auto-merge" in the repository settings.

@gitar-bot gitar-bot Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Gitar has auto-approved this PR and enabled auto-merge (configure)

@gitar-bot gitar-bot Bot added the gitar-approved Added by Gitar label Jul 29, 2026
@hyperpolymath
hyperpolymath merged commit 649bd51 into main Jul 29, 2026
26 checks passed
@hyperpolymath
hyperpolymath deleted the fix/stray-worktree-gitlink branch July 29, 2026 07:31
hyperpolymath added a commit that referenced this pull request Aug 3, 2026
Rebased onto current main and brought the two documents back into agreement
with reality. All figures re-checked; none needed changing.

  - OSSF Scorecard is now PASS. It was dying at checkout on the stray gitlink;
    #145 merged and it has been green on main since. Recorded, with the reason
    it could not be proven on the PR: scorecard.yml triggers only on
    push-to-main / schedule / workflow_dispatch, never on pull_request.
  - #145 marked MERGED rather than open.

New landmine, found while re-baselining: **a merged PR can change nothing.**
Both #146 ("ci(codeql): cron weekly→monthly") and #147 ("Worktree maa ci
repair") are empty — `git diff` between their parents and merge commits is
completely blank. #146's stated change was already present; codeql.yml has read
`cron: '0 6 1 * *'` (monthly) since before it merged.

This is the sibling of the landmine already recorded above it. That one says a
merged PR may not contain the work you pushed; this one says a merged PR may not
contain any work at all. A PR title is not evidence the change happened —
check `git diff --stat <parent> <merge>`.

Verified: asciidoctor renders clean; `yq -p toml` parses STATE.a2ml in full.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

gitar-approved Added by Gitar

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant